<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="content-type" content="text/html; charset=utf-8" />
<title>会员中心 - Powered By ${systemConfig.systemName}</title>
<meta name="Author" content="webmall Team" />
<meta name="Copyright" content="webmall" />
<link rel="icon" href="favicon.ico" type="image/x-icon" />
<#include "/WEB-INF/template/common/include.ftl">
<link href="${base}/template/shop/css/login.css" rel="stylesheet" type="text/css" />
<link href="${base}/template/shop/css/register.css" rel="stylesheet" type="text/css" />
<link href="${base}/template/shop/css/member_center.css" rel="stylesheet" type="text/css" />
<script type="text/javascript" src="${base}/template/shop/js/login.js"></script>
<script type="text/javascript" src="${base}/template/shop/js/register.js"></script>
<script type="text/javascript" src="${base}/template/admin/js/list.js"></script>
<link href="${base}/template/admin/css/pager.css" rel="stylesheet" type="text/css" />
<link href="${base}/template/admin/css/list.css" rel="stylesheet" type="text/css" />
</head>
<body class="memberCenter">
	<#include "/WEB-INF/template/shop/header.ftl">
	<div class="body memberCenterIndex">
		<div class="bodyLeft">
			<#include "/WEB-INF/template/shop/trader_center_left.ftl">
		</div>
				
		<div class="bodyRight">
			<div class="memberCenterDetail list">
				<div class="top">
					商品列表<span class="pageInfo">总记录数: ${pager.totalCount}(共${pager.pageCount}页)</span>
				</div>
				<form id="listForm" action="${base}/member/product!list.action" method="post">
					<div class="operateBar">
						<input type="button" class="addButton" style="float:left;" onclick="location.href='${base}/shop/trader_center!productCategory.action'" value="添加商品" />
						<label>查找:</label>
						<select name="pager.property">
							<option value="name" <#if pager.property == "name">selected="selected" </#if>>
								商品名称
							</option>
							<option value="productSn" <#if pager.property == "productSn">selected="selected" </#if>>
								货号
							</option>
						</select>
						<label class="searchText"><input type="text" name="pager.keyword" value="${pager.keyword!}" /></label><input type="button" id="searchButton" class="searchButton" value="" />
						<label>每页显示:</label>
						<select name="pager.pageSize" id="pageSize">
							<option value="10" <#if pager.pageSize == 10>selected="selected" </#if>>
								10
							</option>
							<option value="20" <#if pager.pageSize == 20>selected="selected" </#if>>
								20
							</option>
							<option value="50" <#if pager.pageSize == 50>selected="selected" </#if>>
								50
							</option>
							<option value="100" <#if pager.pageSize == 100>selected="selected" </#if>>
								100
							</option>
						</select>
					</div>
					<table class="listTable">
						<tr>
							<th class="check" style="width:30px;">
								<input type="checkbox" class="allCheck" />
							</th>
							<th style="width:160px;">
								<span class="sort" name="name">商品名称</span>
							</th>
							<th style="width:130px;">
								<span class="sort" name="productSn">货号</span>
							</th>
							<th>
								<span class="sort" name="productCategory">分类</span>
							</th>
							<th>
								<span class="sort" name="price">价格(元)</span>
							</th>
							<th>
								<span class="sort" name="isMarketable">上架</span>
							</th>
							
							
							<th>
								操作
							</th>
						</tr>
						<#list pager.list as list>
							<tr>
								<td>
									<input type="checkbox" name="ids" value="${list.id}" />
								</td>
								<td>
									<#if (list.name?length <= 10)!>
										<span title="${list.name}">${list.name}</span>
									<#else>
										<span title="${list.name}">${list.name[0..10]}...</span>
									</#if>
								</td>
								<td>
									${list.productSn}
								</td>
								<td>
									${list.productCategory.name}
								</td>
								<td>
									${list.price?string(priceCurrencyFormat)}
								</td>
								<td>
									<#if list.isMarketable == true>
										<img src="${base}/template/admin/images/list_true_icon.gif" />
									<#else>
										<img src="${base}/template/admin/images/list_false_icon.gif" />
									</#if>
								</td>
								
								
								<td>
									<a href="productstore!edit.action?id=${list.id}" title="编辑">[编辑]</a>
									<#if list.isMarketable == true>
										<a href="${base}${list.htmlFilePath}" target="_blank" title="浏览">[浏览]</a>
									<#else>
										<span title="未上架">[未上架]</span>
									</#if>
								</td>
							</tr>
						</#list>
					</table>
					<#if (pager.list?size > 0)>
						<div class="pagerBar">
							<input type="button" class="deleteButton" url="productstore!delete.action" value="删 除" disabled hidefocus="true" />
							<#include "/WEB-INF/template/admin/pager.ftl" />
						</div>
					<#else>
						<div class="noRecord">
							没有找到任何记录!
						</div>
					</#if>
				</form>
				
				<div class="bottom"></div>
			</div>
		</div>
		
		<div class="blank"></div>
		<#include "/WEB-INF/template/shop/friend_link.ftl">
	</div>
	<div class="blank"></div>
	<#include "/WEB-INF/template/shop/footer.ftl">
</body>
</html>
